using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Data;
using System.Text;
using System.Windows.Forms;
using sCicero;

namespace sCicero
{
    public partial class period_new : UserControl
    {

        private sCicero.scicero m_osCicero;

        public period_new(ref sCicero.scicero osCicero)
        {
            m_osCicero = osCicero;
            InitializeComponent();
        }

        private void button1_Click(object sender, EventArgs e)
        {
            period_copy oPeriodCopy = new period_copy(ref m_osCicero, this.textBox_period.Text.Trim());
            oPeriodCopy.ShowDialog();
            
            //m_osCicero.Periods.New(this.textBox_period.Text.Trim(), true);
            m_osCicero.Event.Raise_UpdateRequest(this, "Ny termin skapad: " + textBox_period.Text.Trim(), true); 
        }

        private void groupBox1_Enter(object sender, EventArgs e)
        {

        }

        private void period_new_Load(object sender, EventArgs e)
        {
            textBox_period.Focus();
        }
    }
}
